#ifndef LOG_HPP
#define LOG_HPP

#include <QString>
#include <QFile>
#include <QTextStream>

#include "singleton.hpp"

namespace Log
{
    class Log : public Singleton<Log>
    {
        friend class Singleton<Log>;

        private:
            QFile _file;

        public:
            void setFileName(const QString & fileName);
            void write(const char * msg, const char * msg2 = 0);
    };

    void init(const QString & fileName);
    void myMessageOutput(QtMsgType type, const char * msg);
}



#endif // LOG_HPP
